package day28_35.day30;

import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;

public class Main02 {
    public static void main(String[] args) {
        Scanner scn = new Scanner(System.in);
        while (scn.hasNext()){
            String str = scn.nextLine();
            String[] num = str.split("<br/>");
            StringBuffer strBf = new StringBuffer();
            for (int i = 0; i < num.length; i++) {
                int n = Integer.parseInt(num[i]);
                Set<Integer> set = fun1(n);
                strBf.append(set.size());
                if (i != num.length - 1){
                    strBf.append("<br/>");
                }
            }
            System.out.println(strBf);
        }
    }
    public static Set<Integer> fun1(int n){
        Set<Integer> set = new HashSet<>();
        for (int i = 2 ; i <= n / 2 ; i++){
            if (n % i == 0){
                if (fun2(i)){
                    set.add(i);
                }
            }
        }
        return set;
    }
    public static boolean fun2(int n){
        for (int i = 2 ; i <= Math.sqrt(n) ; i++){
            if (n % i == 0){
                return false;
            }
        }
        return true;
    }
    public static boolean fun3(int n){
        for (int i = 2 ; i <= Math.sqrt(n) ; i++){
            if (n % i == 0){
                return false;
            }
        }
        return true;
    }

}
